<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <script>
        // let arr = [12, 5, 8, 33, 99];

        // for (let i in arr) {
        //     alert(i); // 0, 1, 2, 3, 4
        // }

        // for (let i of arr) {
        //     alert(i); // 12, 5, 8, 33, 99
        // }
    </script>

    <script>
        let json = {
            a: 12,
            b: 5,
            c: 99
        }

        for (let i in json) {
            alert(i); // a, b, c
        }

        for (let i of json) {

        }
    </script>
</body>

</html>